import request from '@/utils/request'

// 查询企业检查记录列表
export function listCompanyrecord(query) {
  return request({
    url: '/system/companyrecord/list',
    method: 'get',
    params: query
  })
}
// 查询企业检查记录列表(含细单)
export function listCompanyrecordWithDtl(query) {
  return request({
    url: '/system/companyrecord/list2',
    method: 'get',
    params: query
  })
}

// 查询企业检查记录详细
export function getCompanyrecord(id) {
  return request({
    url: '/system/companyrecord/' + id,
    method: 'get'
  })
}

// 新增企业检查记录
export function addCompanyrecord(data) {
  return request({
    url: '/system/companyrecord',
    method: 'post',
    data: data
  })
}

// 修改企业检查记录
export function updateCompanyrecord(data) {
  return request({
    url: '/system/companyrecord',
    method: 'put',
    data: data
  })
}

// 删除企业检查记录
export function delCompanyrecord(id) {
  return request({
    url: '/system/companyrecord/' + id,
    method: 'delete'
  })
}


// 删除照片
export function delphoto(params) {
  return request({
    url: '/companyrecord/delphoto',
    method: 'get',
    params
  })
}

// 导入
export const importData = process.env.VUE_APP_BASE_API + '/system/companyrecord/importExcel'
